﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Praxis.Entities;
using Praxis.Repository;
using Microsoft.Practices.Unity;

namespace Praxis.BusinessLogic
{
    public class AlquilerBL:IAlquilerBL
    {
        [Dependency]
        public IAlquilerDAO ialquilerDAO { get; set; }


        public ALQUILER GetAlquilerById(int id)
        {
            return ialquilerDAO.GetAlquilerById(id);
        }

        public void AddAlquiler(ALQUILER alquiler)
        {
            ialquilerDAO.AddAlquiler(alquiler);
        }

        public void UpdateAlquiler(ALQUILER alquiler)
        {
            ialquilerDAO.UpdateAlquiler(alquiler);
        }

        public void RemoveAlquoler(int id)
        {
            throw new NotImplementedException();
        }

        public List<ALQUILER> GetAllAlquiler()
        {
            return ialquilerDAO.GetAllAlquiler();
        }


        public List<ALQUILER> GetAlquilerByCliente(string cliente)
        {
            return ialquilerDAO.GetAlquilerByCliente(cliente);
        }

        public List<ALQUILER> GetAlquilerByObra(string obra)
        {
            return ialquilerDAO.GetAlquilerByObra(obra);
        }
    }
}
